﻿<%@ Page Title="Add new photo" Language="C#" MasterPageFile="~/Content.Master" AutoEventWireup="true" CodeBehind="AddPhoto.aspx.cs" Inherits="MusaDor.Publisher.AddPhoto" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <link rel="stylesheet" href="../Scripts/chosen-master/chosen/chosen.css" />
    <script type="text/javascript" src="../Scripts/jquery-1.4.1.js"></script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
        <div id="RightSide">
            <table class="table">
                <tr>
                    <td class="leftColumn">
                         Category:
                    </td>
                    <td class="rightColumn">
                        <asp:SqlDataSource ID="CategoriesSqlDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>" SelectCommand="SELECT [CategoryID], [Title] FROM [md_Categories] WHERE ([Type] = @Type)">
                            <SelectParameters>
                                <asp:Parameter DefaultValue="Gallery" Name="Type" Type="String" />
                            </SelectParameters>
                        </asp:SqlDataSource>                    
                    </td>
                </tr>
                <tr>
                    <td class="leftColumn">
                        <asp:DropDownList ID="Categories" runat="server" 
                            DataSourceID="CategoriesSqlDataSource" DataTextField="Title" 
                            DataValueField="CategoryID" class="chzn-select" Width="100%"></asp:DropDownList>                    
                        <script src="../Scripts/chosen-master/chosen/chosen.proto.js" type="text/javascript"></script>
                    </td>
                </tr>
                <tr>
                    <td class="leftColumn">
                        <br />
                        Title*:
                    </td>
                </tr>
                <tr>
                    <td class="leftColumn">
                        <asp:TextBox class="headerinput" ID="TextBoxTitle" MaxLength="256" runat="server"></asp:TextBox>
                    </td>
                    <td class="rightColumn">
                        <asp:RequiredFieldValidator ID="RequiredFieldValidatorTitle" runat="server" ErrorMessage="Введите заголовок" ControlToValidate="TextBoxTitle" ForeColor="#FF3300" CssClass="Validation"></asp:RequiredFieldValidator>                    
                    </td>
                </tr>
                <tr>
                    <td>
                        <br />
                        Image (miniature | 200x200 | .jpg)*:
                    </td>
                </tr>
                <tr>
                    <td>
                        <asp:FileUpload ID="PreviewImageUpload" runat="server" CssClass="UploadPhoto"/>
                    </td>
                    <td class="rightColumn">
                        <asp:Label ID="PreviewImageUploadStatus" runat="server" Text=" "></asp:Label>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidatorPreviewImage" runat="server"  ErrorMessage="Select a miniature" ControlToValidate="PreviewImageUpload"  ForeColor="#FF3300"></asp:RequiredFieldValidator>                    
                    </td>
                </tr>
                <tr>
                    <td >
                        <br />
                        Image (full | .jpg)*:
                    </td>
                </tr>
                <tr>
                    <td>
                        <asp:FileUpload ID="FullImageUpload" runat="server" BackColor="White" 
                            CssClass="UploadPhoto"/>                        
                    </td>
                    <td class="rightColumn">
                        <asp:Label ID="FullImageUploadStatus" runat="server" Text=" " CssClass="Error"></asp:Label>
                        <asp:RequiredFieldValidator ID="RequiredFieldValidatorFullImage" runat="server" ErrorMessage="Select a full image" ControlToValidate="FullImageUpload" ForeColor="#FF3300"></asp:RequiredFieldValidator>                                        
                    </td>
                </tr>
            </table>
            <br />
            <div class="bp">
                <asp:Button ID="Send" runat="server" Text="Send" onclick="Send_Click"  CssClass="Send"/>            
            </div>
        </div>

</asp:Content>
